package top.jamsee.controller;

import org.springframework.stereotype.Controller;
import top.jamsee.entity.User;

import javax.annotation.Resource;
import javax.servlet.http.HttpSession;
@Controller
public class BaseController {
    @Resource
    protected HttpSession session;
    public User getUserFromSession(){
        return (User) session.getAttribute("user");
    }
}
